<template>
  <div class="select-test">
    <h3>下拉框测试组件</h3>
    <el-form :inline="true" :model="form" class="test-form">
      <el-form-item label="教练类型">
        <el-select v-model="form.type" placeholder="请选择教练类型" style="width: 200px;">
          <el-option label="科目二教练" value="subject2" />
          <el-option label="科目三教练" value="subject3" />
          <el-option label="理论教练" value="theory" />
        </el-select>
      </el-form-item>
      <el-form-item label="状态">
        <el-select v-model="form.status" placeholder="请选择状态" style="width: 200px;">
          <el-option label="在职" value="active" />
          <el-option label="休假" value="vacation" />
          <el-option label="离职" value="resigned" />
        </el-select>
      </el-form-item>
    </el-form>
    <p>当前选择的值: 教练类型={{ form.type }}, 状态={{ form.status }}</p>
  </div>
</template>

<script setup>
import { reactive } from 'vue'

// 表单数据
const form = reactive({
  type: 'subject2',
  status: 'active'
})
</script>

<style scoped>
.select-test {
  padding: 20px;
}

.test-form {
  margin-bottom: 20px;
}
</style>